<template>
  <div class="nav" :class="{darkNav:darkTheme}">
    <div class="nav-inner">
        <h2>友情链接</h2>
      <img src="../../../public/img/news.png" alt="">
      
    </div>
  </div>
</template>

<script>
import {mapState} from 'vuex'
export default {
  data(){
    return{
      value: new Date(),
    }
  },
  computed:{
    ...mapState("common",["darkTheme"])
  }
}
</script>

<style lang="scss">
.nav{
  position: fixed;
  width: 280px;
  top: 80px;
  margin-left: 20px;
  height: 300px;
  background-color: aliceblue;
}

.nav-inner{
    position: relative;
    box-sizing: border-box;
    padding: 20px;
}
.nav-inner h2{
  text-indent: .5em;
  text-align: left;
  color: #409EFF;
  border-left: 3px solid #409EFF;
  margin-bottom: 20px;
}
.nav-inner img{
      width: 100%;
}  

/* 暗夜主题 */
.darkNav{
  background-color: #263c4f;
  border: 1px solid #2196f3;
  border-radius: 3px;
}
</style>